<#include "/common/defaultEngine.html"/>
<@pageTheme mark="${config.optimize()?string('true', 'false')}">
<@header title="新增ERP人事账户更新" bodyClass="white-bg"  libs=["prism","bootstrapSelect","ueditor"]/>
<div class="wrapper wrapper-content ibox-content">
    <@form.form id="form-accountupdate-add"  class="form-horizontal">
    <input name="id" value="${bpmErpPersonAccountupdate.id}" type="hidden">
    <div class="form-group"><label class="col-sm-3 control-label"><@ctx.i18n text = "流水号"/>：
    </label>
        <div class="col-sm-8"><input name="serialNumber" value="${bpmErpPersonAccountupdate.serialNumber}" class="form-control" type="text" readonly="true">
        </div>
    </div>
    <div class="form-group"><label class="col-sm-3 control-label"><@ctx.i18n text = "申请人"/>：
    </label>
        <div class="col-sm-8"><input name="applyUsername" value="${bpmErpPersonAccountupdate.applyUsername?default('')}" class="form-control" type="text" readonly="true">
        </div>
    </div>
    <div class="form-group">
        <label class="col-sm-3 control-label"><@ctx.i18n text = "账户类型"/>：</label>
        <div class="col-sm-8">
            <@form.select name="accountType" dictType="sys_erp_select_account" value="${bpmErpPersonAccountupdate.accountType?default('')}" readOnly="true" />
        </div>
    </div>
    <div class="form-group">        <label class="col-sm-3 control-label"><@ctx.i18n text = "受益人名称"/>：
    </label>
        <div class="col-sm-8"><input name="beneficiaryUsername" value="${bpmErpPersonAccountupdate.beneficiaryUsername?default('')}" class="form-control" type="text"  readonly="true">
        </div>
    </div>
    <div class="form-group">
        <label class="col-sm-3 control-label"><@ctx.i18n text = "薪资类型"/>：</label>
        <div class="col-sm-8">
            <@form.select name="salaryType" dictType="sys_erp_salary_type" value="${bpmErpPersonAccountupdate.salaryType?default('')}" readOnly="true" />
        </div>
    </div>
    <div class="form-group">        <label class="col-sm-3 control-label"><@ctx.i18n text = "金额"/>：
    </label>
        <div class="col-sm-8"><input name="salaryMoney" value="${bpmErpPersonAccountupdate.salaryMoney?default('')}" class="form-control" type="text"  readonly="true">
        </div>
    </div>
    <div class="form-group">        <label class="col-sm-3 control-label"><@ctx.i18n text = "相关附件"/>：
    </label>
        <div class="col-sm-8">

            <div class="layui-upload">
                <div class="layui-upload-list layui-upList-minHeight uploadpadding">
                    <table class="layui-table">
                        <thead>
                        <tr>
                            <th>文件名</th>
                            <th>大小</th>
                            <th>状态</th>
                            <th>操作</th>
                        </tr>
                        </thead>
                        <tbody id="demojiazhaoList">
                        <tr id="upjiazhaoload"></tr>
                        <#list proof as item>
                        <tr id="upload${item_index}">
                            <td> ${item.fileName?default("")}</td>
                            <td> ${item.fileSize?default("")}</td>
                            <td>已上传</td>
                            <td>
                                <a class="btn btn-danger btn-sm" href="#" download="${item.url}"><i class="fa fa-download"></i></a>
                            </td>
                        </tr>
                        </#list>
                        </tbody>
                    </table>
                </div>
            </div>

        </div>
    </div>
    <div class="form-group">
        <label class="col-sm-3 control-label"><@ctx.i18n text = "备注"/>：</label>
        <div class="col-sm-8">
            <textarea name="salaryRemark" class="form-control" readonly="true">${bpmErpPersonAccountupdate.salaryRemark?default('')}</textarea>
        </div>
    </div>

    <div class="form-group">
        <label class="col-sm-3 control-label"><@ctx.i18n text = "财务经理审批"/>：</label>
        <div class="col-sm-8">
            <@form.radio name="managerApproval" dictType="sys_crm_isOrNo" value="${bpmErpPersonAccountupdate.managerApproval?default('')}" readOnly="true" />
        </div>
    </div>
    <div class="form-group">
        <label class="col-sm-3 control-label"><@ctx.i18n text = "财务经理备注"/>：</label>
        <div class="col-sm-8">
            <textarea name="managerRemark" class="form-control" readonly="true">${bpmErpPersonAccountupdate.managerRemark?default('')}</textarea>
        </div>
    </div>

<#if bpmErpPersonAccountupdate.processStatus==2 >
    <div class="form-group">        <label class="col-sm-3 control-label"><@ctx.i18n text = "会计人员"/>：
    </label>
        <div class="col-sm-8"><input name="accountingPerson" value="${user.id}" class="form-control" type="text" readonly="true">
        </div>
    </div>
    <div class="form-group">
        <label class="col-sm-3 control-label"><span style="color: red; ">*</span><@ctx.i18n text = "会计审批"/>：</label>
        <div class="col-sm-8">
            <@form.radio name="accountingApproval" dictType="sys_crm_isOrNo" value="${bpmErpPersonAccountupdate.accountingApproval?default('1')}" />
        </div>
    </div>
    <div class="form-group">
        <label class="col-sm-3 control-label"><span style="color: red; ">*</span><@ctx.i18n text = "会计备注"/>：</label>
        <div class="col-sm-8">
            <textarea name="accountingRemark" class="form-control" required></textarea>
        </div>
    </div>
</#if>
<#if bpmErpPersonAccountupdate.processStatus!=2 >
<div class="form-group">        <label class="col-sm-3 control-label"><@ctx.i18n text = "会计人员"/>：
</label>
    <div class="col-sm-8"><input name="accountingPerson" value="${bpmErpPersonAccountupdate.accountingPerson?default('')}" class="form-control" type="text"  readonly="true">
    </div>
</div>
<div class="form-group">
    <label class="col-sm-3 control-label"><@ctx.i18n text = "会计审批"/>：</label>
    <div class="col-sm-8">
        <@form.radio name="accountingApproval" dictType="sys_crm_isOrNo" value="${bpmErpPersonAccountupdate.accountingApproval?default('')}" readOnly="true" />
    </div>
</div>
<div class="form-group">
    <label class="col-sm-3 control-label"><@ctx.i18n text = "会计备注"/>：</label>
    <div class="col-sm-8">
        <textarea name="accountingRemark" class="form-control" readonly="true">${bpmErpPersonAccountupdate.accountingRemark?default("")}</textarea>
    </div>
</div>
<div class="form-group">
    <label class="col-sm-3 control-label"><@ctx.i18n text = "会计通过时间"/>：</label>
    <div class="col-sm-8">
        <div class="input-group date">
            <span class="input-group-addon"><i class="fa fa-calendar"></i></span>
            <input class="form-control" name="accountingCrossTime"  data-type="date" value="${(bpmErpPersonAccountupdate.accountingCrossTime?string('yyyy-MM-dd HH:mm:ss'))!}" type="text"  readonly="true"/>
        </div>
    </div>
</div>
</#if>

</@form.form>
</div>
<@footer>
<script type="text/javascript">
    var prefix = baseURL + "erp/accountupdate"
    $("#form-accountupdate-add").validate({
        focusCleanup: true
    });

    function submitHandler() {
        if (opt.validate.form()) {
            opt.operate.save(prefix + "/view3", $('#form-accountupdate-add').serialize());
        }
    }
</script>
</@footer>
</@pageTheme>